<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>仿站电商平台</title>
  <style>
    * {
      margin: 0 auto;
      padding: 0;
    }
    
    h1 {
      width: 80%;
      height: 80px;
      display: flex;
      justify-content: center;
      align-items: center;
      background-color: skyblue;
      color: white;
    }

    form {
      width: 600px;
      display: flex;
      flex-direction: column;
      padding: 20px;
      border: 3px solid pink;
      border-radius: 15px;
      margin: 30px auto;
      padding-top: 50px;
      position: relative;
    }

    form>label {
      height: 50px;
      font-size: 22px;
    }

    form>label>input {
      padding-left: 20px;
      font-size: 22px;
    }

    form>button {
      font-size: 22px;
    }

    form>span {
      position: absolute;
      left: 50%;
      transform: translateX(-50%);
      top: 10px;
      color: red;
      display: none;
    }

    form>span.active {
      display: block;
    }
  </style>
</head>

<body>

  <h1>登录页</h1>

  <form>                    <!-- 表单，包含用户名密码输入框，登录按钮，以及错误提示，绑定提交事件，和阻止默认行为：默认提交 -->       
    <span class="error">用户名密码错误, 请重试</span>
    <label>
      用户名: <input class="username" type="text">
    </label>
    <label>
      密码: <input class="pwd" type="password"style="margin-left: 24px">
    </label>
    <label for="">
      没有账号?
      <a href="./register.html">去注册</a>
    </label>
    <button>登录</button>
  </form>
  <script src="./js/axios.min.js"></script>
  <script src="./js/http.js"></script>
  <script src="./js/login.js"></script>
</body>

</html>